package com.example.anno.registry;

import org.springframework.beans.BeansException;
import org.springframework.beans.factory.support.BeanDefinitionRegistry;
import org.springframework.beans.factory.support.BeanDefinitionRegistryPostProcessor;
import org.springframework.core.Ordered;
import org.springframework.core.PriorityOrdered;
import org.springframework.stereotype.Component;

// @Component
public class CustomPrioryOrderedRegistry implements BeanDefinitionRegistryPostProcessor, PriorityOrdered {
    @Override
    public void postProcessBeanDefinitionRegistry(BeanDefinitionRegistry registry)
            throws BeansException {
        System.out.println("->Priory Ordered Registry Post Process") ;
    }

    @Override
    public int getOrder() {
        return Integer.MAX_VALUE;
    }
}
